package com.songlin.houxin.admin.api.enums;


/**
 * @author jinYuLinLang
 * @version 1.0.0
 * @ClassName LevelEnum.java
 * @Description <p></p>
 * @createTime 2022-03-27 10:40:00
 */
public enum LevelEnum {


    /**
     * 一级
     */
    LEVEL_1(1, "一级"),
    /**
     * 二级
     */
    LEVEL_2(2, "二级"),
    /**
     * 三级
     */
    LEVEL_3(3, "三级");

    private Integer level;

    private String name;

    LevelEnum(Integer level, String name) {
        this.level = level;
        this.name = name;
    }

    public static String getLevelName(Integer level) {
        for (LevelEnum value : values()) {
            if (value.level.equals(level)) {
                return value.name;
            }
        }
        return null;

    }
}
